<template>
  <div class="gotop-gocart">
    <div class="gotop">
      <i class="iconfont icon-huidaodingbu" @click="backTop"></i>
    </div>
  </div>
</template>
<script>
export default {
  // props: ['prolist'],
  methods: {
    backTop () {
      document.getElementsByClassName('box').scrollTop = 0
    }
  }
}
</script>

<style lang="scss">
@import '@/lib/reset.scss';
.gotop-gocart {
  position: fixed;
  z-index: 10;
  width: auto;
  height: auto;
  background-color: transparent;
  right: .2rem;
  bottom: .8rem;
  .gocart {
    margin-top: 0.08rem;
  }
  .gotop {
    width: 0.4rem;
    height: 0.4rem;
    background-color: #fff;
    border-radius: 50%;
    text-align: center;
    line-height: 0.4rem;
    border: 0.01rem solid #ccc;
    i {
      font-size: .22rem;
    }
  }
}
</style>
